package examples.socialNetwork;

public class Friend implements Comparable<Friend>
{
	String name;

	public Friend(String hisName)
	{
		name = hisName;
	}

	public int compareTo(Friend otherFriend)
	{
		return name.compareTo(otherFriend.name);
	}

	public boolean equals(Object another)
	{
		return name.equals(((Friend) another).name);
	}

	public String toString()
	{
		return name;
	}
}
